class Music(val title: String, val artist: String, val duration: Int) {
  override def toString: String = s"$title - $artist ($duration seconds)"
}
class MusicPlayer {
  import scala.collection.mutable.ListBuffer
  private val musicList = ListBuffer[Music]()
  private var currentMusic: Option[Music] = None
  object PlayMode extends Enumeration {
    type PlayMode = Value
    val Sequential, Random, Loop = Value
  }
  import PlayMode._
  private var playMode: PlayMode = Sequential
  def addMusic(musics: Music*): Unit = {
    musicList ++= musics
